163cae
@@ -439,7 +439,7 @@
public int createDynamicBucket(int bucketNum) {
   protected transient boolean autoDelete = false;
   protected transient JobConf jc;
   Class<? extends Writable> outputClass;
-  String taskId;
+  String taskId, originalTaskId;
 
   protected boolean filesCreated = false;
 
@@ -504,7 +504,7 @@
protected void initializeOp(Configuration hconf) throws HiveException {
       lbCtx = conf.getLbCtx();
       fsp = prevFsp = null;
       valToPaths = new HashMap<String, FSPaths>();
-      taskId = Utilities.getTaskId(hconf);
+      taskId = originalTaskId = Utilities.getTaskId(hconf);
       initializeSpecPath();
       fs = specPath.getFileSystem(hconf);
 
@@ -1335,7 +1335,7 @@
public void closeOp(boolean abort) throws HiveException {
         }
       }
       if (conf.isMmTable()) {
-        Utilities.writeMmCommitManifest(commitPaths, specPath, fs, taskId,
+        Utilities.writeMmCommitManifest(commitPaths, specPath, fs, originalTaskId,
                 conf.getTableWriteId(), conf.getStatementId(), unionPath, conf.getInsertOverwrite());
       }
       // Only publish stats if this operator's flag was set to gather stats
